xcodeparsinglexer

Xcode 14 does not allow me to make a lex file


When you try to add a file, it only shows templates, but not a .l file.

I tried making a file with a lex.l header and tried to move it but that didn't work as well.


Solution

  • Xcode doesn't have a built-in template for lex. You can create any type of file you want though. Since a lex file is a plain text file you should choose to add a new file and scroll down to the Other section at the end. Then choose "Empty". Name the file as "something.l". You will now have a new, empty text file that you can enter your lex code into.