MCPcopy Create free account
hub / github.com/csmith-project/csmith / RandomDigits

Method RandomDigits

src/SimpleDeltaRndNumGenerator.cpp:176–188  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

174}
175
176std::string
177SimpleDeltaRndNumGenerator::RandomDigits( int num )
178{
179 std::string str;
180 const char* dec1 = AbsRndNumGenerator::get_dec1();
181 while ( num-- )
182 {
183 int x = random_choice(10, NULL, NULL);
184 str += dec1[x];
185 }
186
187 return str;
188}
189
190unsigned int
191SimpleDeltaRndNumGenerator::pure_rnd_upto(const unsigned int bound)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected