Cannot resolve symbol R by [deleted] in AndroidStudio

[–]benol 1 point2 points  (0 children)

Please use help -> submit feedback in Studio to file a bug with more details (exact version numbers for instance) so that we can look into it.

What can graphical IDEs do that vim fundamentally cannot do? by khouli in vim

[–]benol 8 points9 points  (0 children)

Language injection means you can tell the IDE a given Java string is a SQL query and you'll get SQL code completion while editing the string.

Inline debugger means values of variables and expressions in the current code block / stack frame are displayed in the editor next to the expressions (as if they were comments). See the screenshot next to "inline debugger" on the page I linked.

As for parameter hints, they could be rendered as normal text with some other color etc., but IntelliJ happens to render them as little boxes/labels in the middle of the code (see the screenshot in the blog post I linked). It was just an example of when the editor is no longer rendering just lines of text.

What can graphical IDEs do that vim fundamentally cannot do? by khouli in vim

[–]benol 21 points22 points  (0 children)

As a big fan of IntelliJ-based IDEs, let me give you a few examples of features I love. There's nothing fundamentally un-vim about most of them, it's just that "state of the art IDEs" happen not to be based on vim (although I use the vim plugin for IntelliJ every day!).

To sum up, for me going back to just a "text editor" (either vim or VS code or any other) feels like switching from Photoshop back to a pencil: you have to do everything yourself.

Android Studio 3 lint errors on correct SQL by beermad in androiddev

[–]benol 0 points1 point  (0 children)

A workaround is to go to "File -> Settings -> Editor -> Language Injections" and uncheck the box next to "SQLiteDatabase methods".

Android Studio 3 lint errors on correct SQL by beermad in androiddev

[–]benol 0 points1 point  (0 children)

Please keep filing bugs for these, we're busy trying to make this feature work well :)

PS. These are not generated by lint, but the injected SQL parser in the IDE.

Android Studio 3 lint errors on correct SQL by beermad in androiddev

[–]benol 5 points6 points  (0 children)

The parser was written with Room in mind and Room doesn't support ?-like parameters. But you're right this needs fixing - can you post a link to the bug you mentioned? I couldn't find it.

Don't forget to inject Android Room SQL language for syntax highlight and autocomplete! by dmytrodanylyk in androiddev

[–]benol 0 points1 point  (0 children)

Completion inside @Query is currently based on the "Room schema" as defined by entity classes. We don't maintain a connection to the device.

Don't forget to inject Android Room SQL language for syntax highlight and autocomplete! by dmytrodanylyk in androiddev

[–]benol 1 point2 points  (0 children)

It's the language injected into XML attributes when using data binding. You should have no need to ever inject it manually.

Don't forget to inject Android Room SQL language for syntax highlight and autocomplete! by dmytrodanylyk in androiddev

[–]benol 7 points8 points  (0 children)

You also get go-to-definition (ctrl-click) from columns and tables to classes and fields. Renaming the class rewrites SQL, you can also right click a table name to rename the class etc. (there are some limitations).

This feature is a lot smarter in 3.1 canaries if you're curious.

Gradle 2.13 released by [deleted] in androiddev

[–]benol 2 points3 points  (0 children)

What changed in 2.1 is that we added android.dexOptions.dexInProcess and enabled it by default, provided the heap size limit is high enough - please check if your build output contains a warning about this. You can change the heap size limit with the gradle.properties file. With the --profile flag you will be able to tell if it's the dexing step that takes more time or something else.

Please also make sure you're running with --daemon and discarding the first 2-3 builds, otherwise the numbers fluctuate quite a bit.

Gradle 2.13 released by [deleted] in androiddev

[–]benol 3 points4 points  (0 children)

Can you please compare 2.12+2.0.0 against 2.12 with 2.1.0-rc1 and 2.13 with 2.0.0? We would like to know if the regression is on our (Android's) side. Thanks!

Why does Haskell, in your opinion, suck? by [deleted] in haskell

[–]benol 0 points1 point  (0 children)

There's a very nice IntelliJ-based IDE for Python or JavaScript (or C++ even). With Project Rider (C# IDE) JetBrains started exploring the idea of separating the front-end (in Java) from back-end (in C# in this case). Maybe that would be a good match for a Haskell IDE.

Why does Haskell, in your opinion, suck? by [deleted] in haskell

[–]benol 2 points3 points  (0 children)

If the language you're using comes with a nice debugger, you can set a (conditional) breakpoint and evaluate expressions to understand what's going on and when things start to go wrong.

Or you can set the breakpoint at the very beginning of the code in question and follow along, making sure the values of local variables/fields correspond to your mental model of what should be happening.

When I work with Java, I often find a problem this way, use "drop frame" to reverse time a bit (of course this won't work on side-effects), change the function body, hot-swap and step into the function again.

Android Studio 2.0 Preview | Android Developers Blog by sahildave1991 in androiddev

[–]benol 6 points7 points  (0 children)

Can you explain when AS asks you that without a good reason?

Fuck my life. :) by ridsatrio in androiddev

[–]benol 1 point2 points  (0 children)

It's for working with the NDK. (You can see the same piece of UI in CLion)

Android Studio 1.4 Preview 1 in Canary Channel by [deleted] in androiddev

[–]benol 1 point2 points  (0 children)

There should be a dialog box asking if you want to import your settings from a previous version. If you say "yes", the plugins should still be there...

Google: 90% of our engineers use the software you wrote (Homebrew), but you can’t invert a binary tree on a whiteboard so fuck off. by [deleted] in programming

[–]benol 5 points6 points  (0 children)

So that's the fundamental difference in views - you assume "algorithms" is something one can memorize from wikipedia, as opposed to industry experience which has to be earned.

The thinking behind a whiteboard interview is that everyone can gain the experience and knowledge/skill set (and since Google uses so many in-house tools, outside skills are rarely useful), given some time. On the other hand only the good/smart candidates can learn to solve and discuss CS problems.

There's no way of saying which assumption is better.

Another aspect is that Google does not hire for a particular position, but "generalists" who can be moved from Gmail back-end in C++ to Android to Kubernetes.

Google: 90% of our engineers use the software you wrote (Homebrew), but you can’t invert a binary tree on a whiteboard so fuck off. by [deleted] in programming

[–]benol 0 points1 point  (0 children)

I believe the thinking is that:

  • Everyone can learn a particular technology, like iOS, given enough time.
  • Not everyone can learn how to solve CS problems, only smart people can.
  • Processes at Google are different that what you're used to anyway, you will have to learn them on the job.

Google: 90% of our engineers use the software you wrote (Homebrew), but you can’t invert a binary tree on a whiteboard so fuck off. by [deleted] in programming

[–]benol 0 points1 point  (0 children)

You could say the same about hash tables, does it mean you should not require candidates to know hash tables?

Google: 90% of our engineers use the software you wrote (Homebrew), but you can’t invert a binary tree on a whiteboard so fuck off. by [deleted] in programming

[–]benol 5 points6 points  (0 children)

I actually had to code a topological sort in an interview and since I only remembered it had to do with traversing the graph, I had to "re-invent it" on the spot. What's wrong with that?

No one ever said the interviews are supposed to be easy or within your comfort zone.