Comments (2)
This is a “feature” of Go. There is no shadowing in this scenario.
https://golang.org/ref/spec#Short_variable_declarations
Unlike regular variable declarations, a short variable declaration may redeclare variables provided they were originally declared earlier in the same block (or the parameter lists if the block is the function body) with the same type, and at least one of the non-blank variables is new. As a consequence, redeclaration can only appear in a multi-variable short declaration. Redeclaration does not introduce a new variable; it just assigns a new value to the original.
from fuse.
I see, I don't know why I (wrongly) assumed function result vars live in a separate scope.
thanks @mhandugan
from fuse.
Related Issues (20)
- No debug information for RenameOp HOT 1
- InMessage initialization is in a wrong place
- WriteFile does not work in memfs as it is invoked py PID 0 HOT 5
- Operations frequently canceled when accessing a `gcsfuse` mount with a Go application HOT 2
- Writing offset is not in sequential order HOT 2
- alpine getdents64 lost direntries HOT 3
- Proposal to avoid memory copies between jacobsa FUSE library and application code HOT 4
- evaluate using sync.Pool over custom freelists HOT 3
- fuse mount with root failed HOT 7
- 1.8x slower compared to go-fuse HOT 12
- panic: convertInMessage: Can't grow for 262144-byte read HOT 6
- Shared mmap mapping results in -EACCES or -ENODEV HOT 3
- support open with openflag? HOT 3
- Not compatible to fuse3 HOT 1
- why the pagesize is always 4096? HOT 3
- Would you tell me fuseops error messages in detail ? HOT 1
- Compilation error on FreeBSD
- Shift enforced default permissions to an option. HOT 2
- Running tests sometimes hangs at the FUSE level HOT 6
- Switch from Travis to GitHub Actions HOT 1
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 fuse.