Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changed the construction of divider string for the ImGuiShaderUtils. #493

Conversation

lemonade-dm
Copy link
Contributor

It was using curly braces, now it is using parenthesis.
It was causing a compilation on a developers machine.

D:/github/AtomSampleViewer/Gem/Code/Source/Utils/ImGuiShaderUtils.cpp(32,46): error C2398: Element '1': conversion from 'unsigned __int64' to '_Elem' requires a narrowing conversion
3>        with
3>        [
3>            _Elem=char
3>        ]
3>            AZStd::string divider{header.size(), '-'};
3>                                             ^
3>D:/github/AtomSampleViewer/Gem/Code/Source/Utils/ImGuiShaderUtils.cpp(32,53): warning C4267: 'initializing': conversion from 'size_t' to '_Elem', possible loss of data
3>        with
3>        [
3>            _Elem=char
3>        ]
3>            AZStd::string divider{header.size(), '-'};

Signed-off-by: lumberyard-employee-dm 56135373+lumberyard-employee-dm@users.noreply.github.com

It was using curly braces, now it is using parenthesis.
It was causing a compilation on a developers machine.

```
D:/github/AtomSampleViewer/Gem/Code/Source/Utils/ImGuiShaderUtils.cpp(32,46): error C2398: Element '1': conversion from 'unsigned __int64' to '_Elem' requires a narrowing conversion
3>        with
3>        [
3>            _Elem=char
3>        ]
3>            AZStd::string divider{header.size(), '-'};
3>                                             ^
3>D:/github/AtomSampleViewer/Gem/Code/Source/Utils/ImGuiShaderUtils.cpp(32,53): warning C4267: 'initializing': conversion from 'size_t' to '_Elem', possible loss of data
3>        with
3>        [
3>            _Elem=char
3>        ]
3>            AZStd::string divider{header.size(), '-'};
```

Signed-off-by: lumberyard-employee-dm <56135373+lumberyard-employee-dm@users.noreply.github.com>
@lemonade-dm lemonade-dm requested review from invertednormal and a team August 15, 2022 22:31
@lemonade-dm lemonade-dm merged commit 6dbfd3d into o3de:development Aug 16, 2022
@lemonade-dm lemonade-dm deleted the imgui-shader-utils-curly-to-round-brackets branch August 16, 2022 01:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants