In many textbooks, it is often written that a Riemann integrable (bounded) function on a compact interval [a,b] is also Lebesgue-integrable, and the two integrals are equal. My question is that, is measurability of the function (w.r.t. the Borel sigma field) implicitly assumed in these statements, or does it follow automatically from Riemann integrability of the function. I don't think so. Here, I am trying to give a counterexample, and I wish that its truth is confirmed. Let C be the Cantor set. We know that C being uncountable, contains a non-Borel subset, say S. Define f on [0,1] as: f(x)= 1 (if x is in S) and 0 (if x is in [0,1] - S). In other words, f is just the indicator function of S. Clearly, f is not measurable. Now, f being constant on the complement of C, which is open, f is continuous on the complement of C. Since the Lebesgue measure of C is 0, f is continuous Lebesgue-almost-everywhere, hence must be Riemann integrable! Is there any flaw in this counterexample? Any help will be greatly appreciated!