error while compiling: Error parsing translation unit
See original GitHub issueThis shows up only on Windows, anytime I save the file or activate the current buffer. I’ve tried it on a running Linux system and it works fine.
INFO:EasyClangComplete.plugin.view_config: init completer based on libclang
ERROR:EasyClangComplete.plugin.completion.lib_complete: error while compiling: Error parsing translation unit.
Traceback (most recent call last):
File "C:\Program Files\Sublime Text 3\sublime_plugin.py", line 530, in on_activated_async
callback.on_activated_async(v)
File "C:\Users\Satyajith\AppData\Roaming\Sublime Text 3\Packages\EasyClangComplete\EasyClangComplete.py", line 137, in on_activated_async
self.view_config_manager.load_for_view(view, settings)
File "C:\Users\Satyajith\AppData\Roaming\Sublime Text 3\Packages\EasyClangComplete\plugin\view_config.py", line 344, in load_for_view
config = ViewConfig(view, settings)
File "C:\Users\Satyajith\AppData\Roaming\Sublime Text 3\Packages\EasyClangComplete\plugin\view_config.py", line 66, in __init__
self.completer.update(view, settings.errors_on_save)
File "C:\Users\Satyajith\AppData\Roaming\Sublime Text 3\Packages\EasyClangComplete\plugin\completion\lib_complete.py", line 213, in update
self.tu.reparse()
AttributeError: 'NoneType' object has no attribute 'reparse'
Issue Analytics
- State:
- Created 7 years ago
- Comments:7 (4 by maintainers)
Top Results From Across the Web
error while compiling: Error parsing translation unit. · Issue #236
Your error looks like one that occurs if you change settings or update/install the plugin and do not restart the sublime text. Try...
Read more >c++ - Is there a way to get a meaningfull error message when ...
I am trying to compile code at runtime using libclang. I am giving ti deliberately malformed code to try to see how to...
Read more >Developers - error while compiling: Error parsing translation unit. -
I get this error when displaying the console (ubuntu x64 + clang version 4 from default repos ). Tried to use latest libclang...
Read more >Valloric/YouCompleteMe - Gitter
Hello, I am trying to install YCMD with vundle and stuck with that error: ... debug 'ClangParseError: Libclang crashed while parsing the translation...
Read more >Translation unit manipulation - clang
When fatal errors are encountered while parsing a translation unit, semantic analysis is typically stopped early when compiling code.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Ok, so the reason is that your flags are wrong. Consider this line.
There is a number of includes that have to start with
-I
like the last two flags, but start withC:\\
. Change them to-IC:\\
and the problem should be gone.But I agree, that the error message could be better. I will target this as soon as I have time.
Don’t worry. Good software should be able to tell you there is something wrong BEFORE you encounter a cryptic error. I am going to target the usability at some point soon probably. I want this plugin to be as failsafe as possible.