search for: snake_case

Displaying 7 results from an estimated 7 matches for "snake_case".

2019 Feb 01
4
Variable names rule
...tes space and also hurts readability because the start and end of a word are the most important for readnig. [5] So we've got declarations like "LB(L, PSE, LI, DT, TLI, TTI, AC, ORE, VF.Width, IC, &LVL, &CM)" [6] which is quite intimidating to newcomers. If we could also use snake_case variable names then straight away you have an obvious, readable name (Target target). It looks like there's plenty of code that does this already, and it's consistent with our Python code. Also, it makes C idioms like "for (int i = 0; ..." permissible. I realize that there's...
2007 Jul 31
1
changeset 355
...e the workflow goes like this. route = route_path(request_uri) route_path then calls Merb::Router.match(path) klass = resolve_controller(route[:controller]) resolve_controller then splits the controller part of the route with segments = controller_name.split(''/'').map{|s| s.snake_case} However, it appears that Merb::Router.match isn''t handing back "module/class". For example: If I setup say an Admin::Articles controller, with an articles resource, then these are the results of those methods. route = Merb::Dispatcher.route_path("/admin/articles")...
2019 Feb 03
4
Variable names rule
> On Feb 2, 2019, at 8:18 PM, Chris Lattner <clattner at nondot.org> wrote: > > > >> On Feb 1, 2019, at 6:20 AM, Michael Platings via llvm-dev <llvm-dev at lists.llvm.org <mailto:llvm-dev at lists.llvm.org>> wrote: >> >> Hi all, >> >> As application of the naming rules are currently under discussion [1] this seems like a good time
2019 Aug 15
3
Underscores in package names
...examples where having underscores available would have been useful. 1. My primerTree package (2013) was originally primer_tree, but I had to change the name to camelCase to comply with the check requirements. Using camelCase in the package name makes reading code jarring, as the functions all use snake_case. 2. The widely used testthat package would likely be called test_that, like the corresponding function within the package. This also highlights one of the drawbacks of the current situation, without separators the package name is more difficult to read, does it have two t's or three? 3. The ass...
2024 Jun 18
1
[PATCH 2/2] [v5] drm/nouveau: expose GSP-RM logging buffers via debugfs
...u32 fn, void *repv, u32 repc) +{ + struct nvkm_gsp *gsp = priv; + struct nvkm_subdev *subdev = &gsp->subdev; + struct { + u32 ucodeEngDesc; + u32 libosPrintBufSize; + u8 libosPrintBuf[]; Why are those camelCase? Please use snake_case instead. Sure. They match the names from OpenRM (see g_rpc-structures.h). I'll change them, though. When I copy a struct directly from OpenRM, I prefer to keep it as identical as possible to make it easier to see the connection. I'll move this to a distinct struct and rename the fields...
2019 Feb 04
2
Variable names rule
...ariables, but would also like some other distinction within the universe of variable names. Of course any change to existing conventions would cause some churn and confusion, but we *already* have that, as the current nominal conventions aren't in place in the entire codebase. Regarding snake_case, LLVM has very limited use of that, and only for things that are (a) substitutes or (b) extensions of STL features. "iterator_range" for example. camelCase predominates. --paulr From: llvm-dev [mailto:llvm-dev-bounces at lists.llvm.org] On Behalf Of Chris Lattner via llvm-dev Se...
2019 Aug 10
2
Underscores in package names
On 09/08/2019 4:37 p.m., Gabriel Becker wrote: > Duncan, > > > On Fri, Aug 9, 2019 at 1:17 PM Duncan Murdoch <murdoch.duncan at gmail.com > <mailto:murdoch.duncan at gmail.com>> wrote: > > On 09/08/2019 2:41 p.m., Gabriel Becker wrote: > > Note that this proposal would make mypackage_2.3.1 a valid > *package name*, > > whose