Comments (1)
while {
println!("This is executed");
x == 0
}{}
Devil's advocate here -
This form might be misleading to beginners (such as myself) since it's not really a do-while
, it's explicitly a while
with an empty body and a rather complex condition. You can't break
or continue
in it, for example, and at first glance, the syntax kind of obscures what's actually going on.
So I would understand leaving this out so as to not encourage that kind of hackโor perhaps include it, but in the context of "This is technically possible but probably not good form."
from r4cppp.
Related Issues (20)
- `int` is not a valid rust type
- Not the most obvious way to do graphs
- Bad code-section example HOT 2
- unused_mut warning in control-flow.md
- It is just wrong to say C++ array or other containers do not perform bounds checking. HOT 1
- Feedback on destructuring and borrowing
- Description of slice is misleading
- Info: mdbook for this project at github pages
- Can you add description of every variable is default immutable?
- Traits
- Problem with "primitives.md"
- Methods on structs
- Accessing tuple elements using dot notation
- Destructuring pt2 - confusion about temporary variables created in match statements
- Compilation as PDF file HOT 3
- make_unique call typo
- Compile error in enums code HOT 1
- Bad example in "Borrowed Pointers"? HOT 1
- arena error
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from r4cppp.