View Issue Details

IDProjectCategoryView StatusLast Update
0032908Open CASCADEOCCT:Codingpublic2023-03-19 23:17
ReporterddzamaAssigned Toddzama 
PrioritynormalSeverityminor 
Status closedResolutionfixed 
PlatformWindowsOSVC++ 2019 
Product Version7.6.0 
Target Version7.7.0Fixed in Version7.6.3 
Summary0032908: Coding Rules - fix E0349 MSVC compilation error on VS2019/C++20
DescriptionIn VS 2019/std:c++20 forbidden:
//----------------------------------
char* str = new char [128];
std::cin >> str;
//----------------------------------
But:
//----------------------------------
char str [128];
std::str >> str;
 //----------------------------------
is acceptable.
Steps To ReproduceNot required
TagsNo tags attached.
Test case number

Attached Files

  • image.png (6,444 bytes)

Relationships

child of 0032887 assignedddzama Coding - Problem of compilation on VS2019/C++20 

Activities

git

2022-04-05 10:32

administrator   ~0107627

Branch CR32908 has been created by ddzama.

SHA-1: f04dfdc93bf011056057ca063b543144f01fd871


Detailed log of new commits:

Author: Dmitry DZAMA
Date: Wed Mar 30 11:40:11 2022 +0300

    0032908: Get rid of error E0349.
    
    In VS 2019/std:c++20 forbidden:
    //----------------------------------
    char* str = new char [128];
    std::cin >> str;
    //----------------------------------
    But:
    //----------------------------------
    char str [128];
    std::str >> str;
    //----------------------------------
    is acceptable.

git

2022-04-07 14:30

administrator   ~0107690

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 967f35f70669981a47952d3c3a467c1faad7e114

git

2022-04-07 14:38

administrator   ~0107698

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 40409fc74ef7241394fa6c5b9865302179bffeca

git

2022-04-07 15:18

administrator   ~0107717

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 8279175a64bbc9ca603cc7bc7c813a0494cb68c3

kgv

2022-04-08 18:16

developer   ~0107765

@gka, @abv, @msv

Do you know anything about this block in `XSDRAW::LoadDraw()`?
Maybe we could remove it at all?

msv

2022-04-08 20:15

developer   ~0107772

It is not a block in XSDRAW::LoadDraw, it is a separate method XSDRAW::GetList. And it is used in XSDRAWIGES and XSDRAWSTEP.

kgv

2022-04-08 20:55

developer   ~0107773

@msv, could you please review this patch then?

msv

2022-04-11 10:51

developer   ~0107832

@ddzama, as you rewritten the method wholly, please make naming of variables according to OCCT coding rules.

git

2022-04-20 11:28

administrator   ~0108042

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 7e485f74c6f634a1d6743edf5e347384cd5a3fe1

git

2022-04-25 16:24

administrator   ~0108159

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 894479cf64cf5b9e458a9bf40e395ea82f32529b

git

2022-04-26 02:08

administrator   ~0108174

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 78e74ab07ee49268fe02d7421b1c9c0655db7940

kgv

2022-04-26 17:11

developer   ~0108191

Last edited: 2022-04-26 17:12

@msv please take a look onto updated patch.

msv

2022-04-26 17:42

developer   ~0108192

My previous remark was not considered.

git

2022-05-04 12:28

administrator   ~0108290

Branch CR32908 has been updated by ddzama.

SHA-1: c6230c9c846c9f20e83ecea4213cca0ae986e652


Detailed log of new commits:

Author: ddzama
Date: Wed May 4 12:26:43 2022 +0300

    0032908: variables names reduced to `coding rules`

ddzama

2022-05-04 12:29

developer   ~0108291

@msv, done.

kgv

2022-05-04 12:59

developer   ~0108296

@ddzama, please prepare a branch with squashed changes and proper description, switch the bug to appropriate state, and assign to reviewer (Mikhail) to advance through bug advancement workflow.

git

2022-05-04 15:17

administrator   ~0108306

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: f5d83a127127b89d2b9b18968218e0f89f7de9e9

git

2022-05-04 15:54

administrator   ~0108315

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: a5c276031a47eca20d6dc91b6ae1d26ca347390d

msv

2022-05-04 16:49

developer   ~0108321

For integration:
occt - CR32908

kgv

2022-05-04 17:07

developer   ~0108322

Last edited: 2022-05-04 17:08

@ddzama, please remove pointless comments from commit description, just repeating the code from the patch.
Ideally, commit description should complement the patch with helpful details.
image.png (6,444 bytes)

git

2022-05-04 17:20

administrator   ~0108323

Branch CR32908 has been updated forcibly by ddzama.

SHA-1: 7eb2171bcde8c29ccd397a92233386b2d66462cd

ddzama

2022-05-04 17:21

developer   ~0108324

@kgv, done.

msv

2022-05-04 23:40

developer   ~0108328

@ddzama, you should not assign on bugmaster in resolved state. It is reviewer who must assign on bugmaster if no more remarks.

msv

2022-05-04 23:42

developer   ~0108329

Sorry, my message was due to a mistake.

git

2023-01-21 21:18

administrator   ~0112960

Branch CR32908 has been deleted by vglukhik.

SHA-1: 7eb2171bcde8c29ccd397a92233386b2d66462cd

Related Changesets

occt: master 73035770

2022-03-30 11:40:11

ddzama


Committer: smoskvin Details Diff
0032908: Coding Rules - fix E0349 MSVC compilation error on VS2019/C++20

Get rid of raw C strings in error code to avoid error 0349.
Use std::string instead.
Affected Issues
0032908
mod - src/XSDRAW/XSDRAW.cxx Diff File

Issue History

Date Modified Username Field Change
2022-04-05 10:24 ddzama New Issue
2022-04-05 10:24 ddzama Assigned To => ddzama
2022-04-05 10:24 ddzama Relationship added parent of 0032907
2022-04-05 10:25 ddzama Relationship deleted parent of 0032907
2022-04-05 10:26 ddzama Relationship added parent of 0032907
2022-04-05 10:28 ddzama Relationship added child of 0032887
2022-04-05 10:32 git Note Added: 0107627
2022-04-05 10:51 ddzama Relationship added child of 0032909
2022-04-05 11:03 ddzama Relationship deleted child of 0032887
2022-04-07 12:28 kgv Relationship added child of 0032887
2022-04-07 12:28 kgv Relationship deleted child of 0032909
2022-04-07 12:29 kgv Product Version 7.7.0 => 7.6.0
2022-04-07 12:29 kgv Summary Get rid of error E0349. => Coding Rules - fix E0349 MSVC compilation error on Visual Studio 2019
2022-04-07 12:29 kgv Relationship deleted parent of 0032907
2022-04-07 12:35 kgv Summary Coding Rules - fix E0349 MSVC compilation error on Visual Studio 2019 => Coding Rules - fix E0349 MSVC compilation error on VS2019/C++20
2022-04-07 14:30 git Note Added: 0107690
2022-04-07 14:38 git Note Added: 0107698
2022-04-07 14:51 ddzama Relationship deleted child of 0032887
2022-04-07 14:53 ddzama Relationship added child of 0032887
2022-04-07 15:18 git Note Added: 0107717
2022-04-08 18:16 kgv Note Added: 0107765
2022-04-08 20:15 msv Note Added: 0107772
2022-04-08 20:55 kgv Assigned To ddzama => msv
2022-04-08 20:55 kgv Status new => resolved
2022-04-08 20:55 kgv Note Added: 0107773
2022-04-11 10:51 msv Note Added: 0107832
2022-04-11 10:52 msv Assigned To msv => ddzama
2022-04-11 10:52 msv Status resolved => assigned
2022-04-20 11:28 git Note Added: 0108042
2022-04-25 16:24 git Note Added: 0108159
2022-04-26 02:08 git Note Added: 0108174
2022-04-26 11:26 ddzama Assigned To ddzama => kgv
2022-04-26 11:26 ddzama Status assigned => resolved
2022-04-26 11:26 ddzama Steps to Reproduce Updated
2022-04-26 17:11 kgv Assigned To kgv => msv
2022-04-26 17:11 kgv Note Added: 0108191
2022-04-26 17:12 kgv Note Edited: 0108191
2022-04-26 17:42 msv Note Added: 0108192
2022-04-26 17:42 msv Assigned To msv => ddzama
2022-04-26 17:42 msv Status resolved => assigned
2022-05-04 12:28 git Note Added: 0108290
2022-05-04 12:29 ddzama Note Added: 0108291
2022-05-04 12:59 kgv Note Added: 0108296
2022-05-04 15:17 git Note Added: 0108306
2022-05-04 15:54 git Note Added: 0108315
2022-05-04 15:55 ddzama Assigned To ddzama => msv
2022-05-04 15:55 ddzama Status assigned => resolved
2022-05-04 15:56 ddzama Status resolved => reviewed
2022-05-04 16:49 msv Note Added: 0108321
2022-05-04 17:07 kgv Note Added: 0108322
2022-05-04 17:07 kgv File Added: image.png
2022-05-04 17:07 kgv Assigned To msv => ddzama
2022-05-04 17:07 kgv Status reviewed => assigned
2022-05-04 17:08 kgv Note Edited: 0108322
2022-05-04 17:20 git Note Added: 0108323
2022-05-04 17:21 ddzama Note Added: 0108324
2022-05-04 18:19 kgv Assigned To ddzama => bugmaster
2022-05-04 18:19 kgv Status assigned => resolved
2022-05-04 18:19 kgv Status resolved => reviewed
2022-05-04 23:40 msv Note Added: 0108328
2022-05-04 23:42 msv Note Added: 0108329
2022-05-08 13:54 bugmaster Status reviewed => tested
2022-05-08 16:15 smoskvin Changeset attached => occt master 73035770
2022-05-08 16:15 ddzama Assigned To bugmaster => ddzama
2022-05-08 16:15 ddzama Status tested => verified
2022-05-08 16:15 ddzama Resolution open => fixed
2023-01-21 21:18 git Note Added: 0112960
2023-03-19 23:17 vglukhik Status verified => closed
2023-03-19 23:17 vglukhik Fixed in Version => 7.6.3