Skip to main content
Stack Overflow
  1. About
  2. For Teams
Filter by
Sorted by
Tagged with
0 votes
1 answer
114 views

In SQL Server 2022, is there an aggregate function for doing a bit-wise OR against a particular column? -- Example table, data and output to show the different flags DECLARE @TEST TABLE (FLAGS TINYINT)...
7 votes
1 answer
338 views

In 6502 assembly, I need to set the value of the Z flag according to bit 2 of the value at address 8000ドル. But I need to do so without overwriting the value in the A register. I've come up with this ...
1 vote
1 answer
97 views

I'm not sure how exactly to formulate this question so I will illustrate by example. I am using the bitflags crate which provides a trait called Flags. The flags trait involves the presence of an ...
Muhr's user avatar
  • 13
2 votes
1 answer
76 views

Can the result of std::fetestexcept return multiple bits set, or does it only ever return a single bit?
Dess's user avatar
  • 2,739
2 votes
2 answers
101 views

I'm a beginner in learning 8086 assembly language using DOSBox. I'm using int 21h function 3Dh to open a data file, and I wanted to carry out the code using the file handle if the file is opened ...
0 votes
1 answer
78 views

I have a bitflag enum EFlags. Given a condition I want to either remove a flag or add a flag. I have defined the operator |= to add a flag and &= to remove a flag. For example, let us say the ...
Eshy's user avatar
  • 441
1 vote
2 answers
104 views

I am setting up an unordered_map, in which the key is an enum of Direction defined as: enum Direction : uint16_t { North = 1 << 0, East = 1 << 2, South = 1 << 3, West ...
1 vote
1 answer
691 views

I have a unity project. Using the stock json tools at my disposal, i'm trying to deserialize an enum that uses bit flags (ie something like) [Flags] enum Terrain { NORMAL = 0, FOREST = 1, SWAMP ...
0 votes
1 answer
106 views

Checking for multiple flags. I just want to know if there is another way to check for multiple flags, different from &&? class DemoClass { public const MY_FLAG1 = 0b1; // 0001 // 1 ...
3 votes
1 answer
1k views

I'm trying to grasp UTF-8 encoding. The encoding of code points can range from 1 to 4 bytes. There are only 128 characters which encode to one byte. But since a byte has 8 bits it could encode 256(=28)...
4 votes
3 answers
151 views

I have a bitmask (really a 'flagmask') of integer values (1, 2, 4, 8, 16 etc.) which apply to a field and I need to store this in a (text) log file. What I effectively store is something like "x=...
roryhewitt's user avatar
  • 4,535
2 votes
2 answers
844 views

I have an enum that represents the directions you're allowed to move for a given cell in a maze: class Direction(Flag): NORTH = 1 EAST = 2 SOUTH = 4 WEST = 8 NE = NORTH | EAST ...
1 vote
1 answer
171 views

I am learning C++'s iostream. In particular, I have learnt that by default the output of cout is right aligned. For example, if I write: #include <iostream> #include <iomanip> int main() { ...
user avatar
0 votes
1 answer
135 views

I have a Number value I'm sending to an API and I want to soft check on the front end if the value is a valid "flag" before shipping it off. So far as I can figure, a flag is any number ...
-1 votes
1 answer
122 views

I am now working on a motion control system. I want to make the motion control interface more flexible, so I want to provide an api that can specifiy the controlled axis. It just like. void moveTo(/*...

15 30 50 per page
1
2 3 4 5
...
9

AltStyle によって変換されたページ (->オリジナル) /