One version of Hartogs' extension theorem is the following (see, e.g. [1], Theorem 5B, p. 50).

**Theorem.** *Let $U \subset \mathbb{C}^n$ be open and let $X \subset U$ be a complex-analytic subvariety of codimension $>1$. Then, any holomorphic function $U \setminus X \to \mathbb{C}$ has a unique holomorphic extension $U \to \mathbb{C}$.*

**Question.** Is this theorem still true if we replace $X$ by a *real-analytic* subvariety of codimension $>2$?

Note that I am still considering holomorphic functions. (The real-analytic version of Hartogs' theorem is false.)

**References.**

[1] Whitney, Hassler. *Complex analytic varieties.* Addison-Wesley Publishing Co., Reading, Mass.-London-Don Mills, Ont., 1972. xii+399 pp.