When a company goes through a restructure, some shareholders may receive cash in lieu of stock. This type of payment can affect your holdings and your capital gains taxes, as it's considered a taxable event, even though it's done without the investor's endorsement.

Definition
What is cash in lieu?
Cash in lieu is a payment to a shareholder made in cash instead of stock. The company sells some of your holdings, and you receive cash for it. This can occur after corporate actions, such as stock splits, that would result in fractional shares for investors.
In this situation, the company's board of directors has a few options to ensure all shareholders receive fair value. It can issue fractional shares, round up shares, or pay cash in lieu of partial stock shares. If the board doesn't want to start offering fractional shares or round up, then it will go with a cash payment for simplicity's sake.
When it happens
When companies distribute cash in lieu of stock
Any company restructuring that affects the number of outstanding shares can lead to a cash in lieu payment. Stock splits and reverse stock splits are two of the more common examples. For example, if a company sets a 5-for-2 stock split, shareholders would receive five shares for every two they own. If you own five shares, the company would need to issue you 12.5 shares. Or, it could issue as many whole shares as possible and pay the rest with cash in lieu.
Other corporate events that can result in fractional shares include mergers and acquisitions and stock spinoffs. Once again, companies would have the option of paying shareholders with fractional shares or cash in lieu.
While any shareholder could receive cash in lieu of stock, it's more likely if you own fractional shares of a company. Since you already have partial shares, it makes dividing up those shares more complicated in a stock split. For example, if you own a half-share of a business that does a 1-for-3 reverse stock split, it would need to issue you one-sixth of a share. The company may elect to pay you in cash to avoid that. There's no way to guarantee you'll never receive cash in lieu of stock, but if you want to do your best to avoid it, stick to buying and selling whole shares in your portfolio.
Reporting on your taxes
How to report cash in lieu on your taxes
If you've received cash in lieu of stock in a taxable account, then you'll need to report it on your taxes using Form 1099-B. You don't need to report if you received it through a tax-advantaged account, such as a 401(k), individual retirement account (IRA), or Roth IRA.
In a taxable account, a cash in lieu payment works the same way as a stock sale. If shares were sold for more than your cost basis, then you owe capital gains taxes on the profits. If shares were sold for less than what you paid for them, then you can claim the capital losses on your taxes. Make sure to check the cost basis and the sale price for your fractional shares so you can accurately calculate your gains or losses.
Related investing topics
Example
Example of cash in lieu
Let's say you purchased 105 shares of a company's stock at $50 per share. Your total cost basis is $5,250. The company announces a 3-for-2 stock split, meaning you'd be due an additional 52.5 shares after the split, bringing your total number of shares to 157.5.
If the company doesn't want to issue fractional shares, it would distribute 52 additional shares and cash in lieu of the fractional share. Because of the stock split, your per-share cost basis would drop to $33.33. You can calculate this by dividing the total number of shares you'd have after the split, 157.5, by your total cost basis of $5,250. If the half-share was sold at a share price of $38, then you'd have capital gains of $4.67.