4coder » Forums » Goto error not working
owmywrists
5 posts
#13824 Goto error not working
3 weeks, 2 days ago

I recently picked up 4coder and I have been testing out features, which so far I think are great.


However, one issue i am having is with goto error. I build my project with cmake and then use a bat file to compile with devenv. Pressing alt + m will open the special build panel which will display my errors but when i move the cursor over them and press enter nothing happens. I may be missing something but any help is greatly appreciated!

nicoco
nj
15 posts
#13828 Goto error not working
3 weeks, 2 days ago

Can you attach an example of the error format you get? for example I know that 4coder need the full path to a file.
There is another bug (I don't think it's your case though) that forces you to wait until the compiliation finishes before going to an error.
owmywrists
5 posts
#13844 Goto error not working
3 weeks ago

1>C:\Users\Oliver\Documents\Programming\CPP\3d_tetris\src\main.cpp(21): error C3688: invalid literal suffix 're4terg'; literal operator or literal operator template 'operator ""re4terg' not found
1>C:\Users\Oliver\Documents\Programming\CPP\3d_tetris\src\main.cpp(22): error C2143: syntax error: missing ';' before '}'

this is the format I get, which seems to look plausible for 4coder to jump to
mrmixer
Simon Anciaux
326 posts
#13847 Goto error not working
3 weeks ago

The problem is the "1>" in front of the file name. 4coder keeps it in the file name: it uses the first non white space character of the line as the start of the filename. You can send an e-mail to Allen with the output example so he can fix it.
In the mean time, if you have access to the "super" version of 4coder you can try to fix it (in 4coder_jumping.h, the parse_jump_location function).
owmywrists
5 posts
#13850 Goto error not working
3 weeks ago

I'll have a go now, thanks! Although, I am having a few problems with compiling files with buildsuper.bat. The default file "4coder_default_bindings.cpp" is never found by the batch file. The error is as followed:


[vcvarsall.bat] Environment initialized for: 'x64'
4coder_metadata_generator.cpp
4coder_default_bindings.cpp
c1xx: fatal error C1083: Cannot open source file: '4coder_default_bindings.cpp': No such file or directory
Could Not Find C:\Users\Oliver\source\*.exp
Could Not Find C:\Users\Oliver\source\*.lib

mrmixer
Simon Anciaux
326 posts
#13852 Goto error not working
2 weeks, 6 days ago

Is the file 4coder_default_bindings.cpp present in the 4coder directory (the one containing buildsuper.bat) ?
Do you have the file opened in another program that may limit the access to it ?
Do you launch the batch file from the 4coder directory (it should not matter but it's worth trying) ?
You can set which file is compiled by passing a file name as the first argument to buildsuper.bat. So maybe try this in a console:
buildsuper.bat 4coder_default_bindings.cpp
owmywrists
5 posts
#13853 Goto error not working
2 weeks, 6 days ago Edited by on Dec. 27, 2017, 8:37 p.m.

Yes it's in the same directory, just as I downloaded it. I tried with only powershell open with no avail. And yes I run it straight from the directory and also parsed in the file I wanted to compile with the same issue.

This is what dir shows:

Mode LastWriteTime Length Name
---- ------------- ------ ----
d----- 24/12/2017 23:51 4coder_API
d----- 24/12/2017 23:51 4coder_generated
d----- 24/12/2017 23:51 4coder_helper
d----- 24/12/2017 23:51 4coder_lib
d----- 27/12/2017 00:53 fonts
d----- 24/12/2017 23:51 languages
d----- 24/12/2017 23:51 themes
d----- 24/12/2017 23:51 windows_scripts
-a---- 24/12/2017 23:51 28089 4coder_auto_indent.cpp
-a---- 24/12/2017 23:51 40379 4coder_base_commands.cpp
-a---- 24/12/2017 23:51 8702 4coder_build_commands.cpp
-a---- 24/12/2017 23:51 5079 4coder_clipboard.cpp
-a---- 24/12/2017 23:51 946 4coder_default_bindings.cpp
-a---- 24/12/2017 23:51 45359 4coder_default_framework.h
-a---- 24/12/2017 23:51 17172 4coder_default_hooks.cpp
-a---- 24/12/2017 23:51 28366 4coder_default_include.cpp
-a---- 24/12/2017 23:51 14064 4coder_function_list.cpp
-a---- 24/12/2017 23:51 13513 4coder_jumping.h
-a---- 24/12/2017 23:51 5276 4coder_jump_direct.cpp
-a---- 24/12/2017 23:51 23707 4coder_jump_sticky.cpp
-a---- 24/12/2017 23:51 35243 4coder_metadata_generator.cpp
-a---- 24/12/2017 23:51 1171 4coder_os_comp_cracking.h
-a---- 24/12/2017 23:51 32235 4coder_project_commands.cpp
-a---- 24/12/2017 23:51 2044 4coder_remapping_commands.cpp
-a---- 24/12/2017 23:51 29521 4coder_scope_commands.cpp
-a---- 24/12/2017 23:51 35870 4coder_search.cpp
-a---- 24/12/2017 23:51 1201 4coder_search.h
-a---- 24/12/2017 23:51 1792 4coder_system_command.cpp
-a---- 24/12/2017 23:51 472064 4ed.exe
-a---- 24/12/2017 23:51 349696 4ed_app.dll
-a---- 24/12/2017 23:51 1010 buildsuper.bat
-a---- 25/12/2017 00:57 1339 config.4coder
-a---- 24/12/2017 23:51 391680 custom_4coder.dll
-a---- 24/12/2017 23:51 1294 LICENSE.txt
-a---- 24/12/2017 23:51 315 README.txt
mrmixer
Simon Anciaux
326 posts
#13858 Goto error not working
2 weeks, 6 days ago

Can you open the "4coder_default_bindings.cpp" file in notepad or another editor ? It sound like something is locking the file, maybe your antivirus or something ?

You could try to compile using this command to see if the problem comes from the batch file (assuming 4coder files are in C:\Users\Olivier\source\ and the metagenerator was run):
1
cl /I"C:\Users\Oliver\source\ " /W4 /wd4310 /wd4100 /wd4201 /wd4505 /wd4996 /wd4127 /wd4510 /wd4512 /wd4610 /wd4457 /WX /GR- /nologo /FC /Zi 4coder_default_bindings.cpp /Fecustom_4coder /LD /link /INCREMENTAL:NO /OPT:REF /EXPORT:get_bindings /EXPORT:get_alpha_4coder_version
Mr4thDimention
Allen Webster
304 posts
2 projects

Heyo

#13859 Goto error not working
2 weeks, 6 days ago

Thanks to everyone helping out on this. I can get the "#>" added to the jump parser in the next build probably.

As for the buildsuper problem, I am a bit stumped, mrmixer's is doing a better job troubleshooting this than I would have done it looks like, so just keep listening to him! If you find a problem with the script let me know and I'll fix it. If the dir you ran was not in the script try that, I think it may do some "cd" or "pushd" stuff that might be moving you to the wrong place or something, but other than that I have no ideas.