Skip to content

Parser does not handle mixed concatenations of wide and non-wide strings

ID0001467: This issue was created automatically from Mantis Issue 1467. Further discussion may take place here.


Id Project Category View Due Date Updated
ID0001467 Frama-C Kernel public 2013-08-07 2017-12-06
Reporter pascal Assigned To valentin.perrelle Resolution fixed
Priority normal Severity feature Reproducibility always
Platform - OS - OS Version -
Product Version Frama-C Fluorine-20130601 Target Version - Fixed in Version Frama-C 16-Sulfur

Description :

~/ppc $ cat tests/misc/wstring_phase6.i /* run.config OPT: -journal-disable -print */

// See http://stackoverflow.com/questions/18102502/mixing-wide-and-narrow-string-literals-in-c main(){ printf( "%s\n", "123" "456" ); printf( "%ls\n", L"123" L"456" ); printf( "%ls\n", "123" L"456" ); printf( "%ls\n", L"123" "456" ); printf( "%ls\n", L"123" L"456" ); } ~/ppc $ bin/toplevel.opt -print tests/misc/wstring_phase6.i tests/misc/wstring_phase6.i:9:[kernel] user error: syntax error [kernel] user error: skipping file "tests/misc/wstring_phase6.i" that has errors. [kernel] Frama-C aborted: invalid user input. ~/ppc $

Additional Information :

As commented in the test, the behavior is defined and is explained in http://stackoverflow.com/questions/18102502/mixing-wide-and-narrow-string-literals-in-c

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information