Skip to main content
0 votes
0 answers
6 views

Viewmodel re initialization while its not cleared after navigating between screens

This is my bottom app bar : ShoppingCartPage-HomePage-ProfilePage-MyOrders-SettingsPage And Two screens: CategoryItemPage - OfferItemPage ( i dont want to save their states) navigation: HomePage -> ...
Hussein Chahine's user avatar
-3 votes
0 answers
21 views

Should I use member or non-member functions when breaking constructors in Go? [closed]

Suppose I have a big, complex struct Foo. type Foo struct { // a big, complex object... } It will be created with the constructor function NewFoo(). Since the object is big and complex, NewFoo() ...
rodrigocfd's user avatar
  • 7,682
-4 votes
1 answer
106 views

What is the difference between `int arr[10]{};` and `int arr[10] = {};`? [duplicate]

I'm trying to understand array and struct initialization. I've seen two variants: int arr[10]{}; int arr[10] = {}; What is the difference between them? I've tried looking in https://godbolt.org/ and ...
Yiftach's user avatar
  • 339
0 votes
0 answers
12 views

NG0203 and NullInjectorError on Angular17 Application with Keycloak

I'm having 2 issues on with my application in the Homolog server, the first issue is the NG0203 when i have an empty cache: ERROR RuntimeError: NG0203: inject() must be called from an core.mjs:6531 ...
peprog's user avatar
  • 1
0 votes
0 answers
29 views

Variable ___ might not have been initialized

I just started learning Java for my programming class and I have to create a decimal to binary calculator where it loops until the user inputs "stop", I'm having trouble with needing a ...
Carlinbhert Toralba's user avatar
0 votes
0 answers
42 views

How to solve Mojo SDK initialization error in VScode?

I installed Max and Mojo, and set up the path correctly, and Mojo works just fine in both Ubuntu wsl and VScode. However, each time I start up VScode, the below message persists: "Mojo SDK ...
Yousef Samir's user avatar
0 votes
1 answer
75 views

Does value-initialization first zero-initialize the members of object even with provided default member initializer in C++?

On value-initialization page cppreference states the following: The effects of value-initialization are: If T is a (possibly cv-qualified) class type: If the default-initialization for T selects a ...
Rebased's user avatar
  • 51
0 votes
2 answers
99 views

Initializing fixed-size array with uninitialized values [closed]

The standard says that reading from an uninitialized variable is undefined behavior. However, suppose I want to construct std::array of uninitialized values of user-defined type Z, which is in fact ...
slobod's user avatar
  • 17
5 votes
1 answer
178 views

Can someone explain the rules of object lifetimes and uninitialized memory in C++ (context: std::inplace_vector)?

I've been trying to implement my own version of std::inplace_vector in C++26; that is, a dynamically-resizable array with compile-time fixed capacity, that also allows non-default-constructible ...
Christopher Miller's user avatar
2 votes
0 answers
44 views

delay block: total pivoting and singular matrix problem

I am working on a larger model in OpenModelica and I keep getting this error: Failed to solve linear system of equations (no. 5) at time 0.000000, system is singular for U[2, 2]. The default linear ...
bertram00's user avatar
0 votes
2 answers
147 views

Reference initialization using list initialization accepted by gcc and msvc but rejected by clang

Consider the following example that compiles with gcc, msvc and edg but is rejected by clang. Demo struct X { public: X(){} }; struct Y : X { }; struct Z { public: operator ...
user12002570's user avatar
  • 49.9k
0 votes
0 answers
86 views

Initialize and use ADE7880 ADC via SPI in Linux

I am working with the ADE7880 ADC and I am attempting to initialize it and use it to read and write registers via SPI in C on a Linux system. My goal is to capture ADC data through SPI, but I am ...
prial joshi 's user avatar
0 votes
0 answers
30 views

PostgreSQL: Problem running post-install step. Installation may not complete correctly.The database cluster initialisation failed

On Windows 10 Enterprise, I've been trying to install multiple PostgreSQL versions (v10, v14, v16), but the installer always gives this error: *Problem running post-install step. Installation may not ...
juliG's user avatar
  • 1
1 vote
1 answer
51 views

Possibility of uninitialized use of b in if (!a) { b = get_b(); } if (a || b) { ... }

When compiling the following (context) with -Oz, extern void *get_table_index(struct table tbl, struct string name); void inspircd2_protocol_propagate_privmsg(struct string from, struct string source,...
Runxi Yu's user avatar
-3 votes
2 answers
141 views

Different notes for uninitialized member inside a generic lambda in GCC 9 and GCC 10

I have noticed an inconsistent behavior in my production C++17 code regarding generic lambdas and notes. I was finally able to break it down to the following minimal example. Gives a note with x86_64 ...
SoulfreezerXP's user avatar

15 30 50 per page
1
2 3 4 5
788