Project

General

Profile

Bug #9653

Frama-C (CIL) incorrectly outputs wide character literals

Added by Evgeny Novikov 6 months ago. Updated 6 months ago.

Status:
Closed
Priority:
High
Start date:
05/16/2019
Due date:
% Done:

0%

Estimated time:
Detected in build:
svn
Platform:
Published in build:

Description

For instance, for such the examples:

typedef short unsigned int wchar_t;
wchar_t *abc, *empty;
abc = L"ABC";
empty = L"";

it outputs something like
typedef short unsigned int wchar_t;
wchar_t *abc, *empty;
abc = L"A" "B" "C";
empty = L;

(if the former is acceptable, the latter is an obvious bug).

I did not investigate if the issue exists with different options, but at least it exists for "-machdep gcc_x86_64 -c11 -short-wchar" (other options are not likely relevant).

History

#1

Updated by Evgeny Novikov 6 months ago

  • Priority changed from Urgent to High

The issue is not so crucial although it is not pleasant.

#2

Updated by Mikhail Mandrykin 6 months ago

  • Status changed from New to Resolved

Fixed in 016f6757. The bug is still present in upstream Frama-C v19 beta (Cil_printer@L538).

#3

Updated by Evgeny Novikov 6 months ago

Mikhail Mandrykin wrote:

Fixed in 016f6757. The bug is still present in upstream Frama-C v19 beta (Cil_printer@L538).

Thank you for the fix, I will test it soon.

Regarding the upstream, please, suggest the bug fix there.

#4

Updated by Evgeny Novikov 6 months ago

  • Status changed from Resolved to Closed

Sorry for delay. I tested the fix. Now everything seems to work.

Also available in: Atom PDF