Problem using SmartTabs in Emacs - emacs

I'm trying to use smarttabs.el from https://gist.github.com/188961 in latest emacs-dev (bzr). When trying to compile or load it I get the error:
smarttabs.el:54:1:Error: Don't know how to make a localized variable an alias
which is completely new to me. How do I correct this?
Also see http://www.emacswiki.org/emacs/SmartTabs for package explanation.

The error message is trying to say that defvaralias (used in the smart-tabs-advice macro) doesn't do what jacius thinks it does. But I'm not quite sure what he thinks it does, so I'm not sure how to fix it. Try reporting the error to him.

Related

How do I fix dart errors?

Now I want to practice converting the code in Dart, but it gives me this error.
I just wanted to try the data conversion.
its just working fine you might have other error. clean the main function and write it again it might solve the problem.
check out this
https://dartpad.dev/?id=2784dae4ab1808b914799e2c0f59420e

breeze mongo manager.saveChanges() error

I'm learning from breeze-zza-mongodb sample.
I get some problems when i try to use the saveChanges() function from breeze.
This is the error i get:
"TypeError: Cannot read property 'update' of null at... node_modules\breeze-mongodb\mongoSaveHandler.js : 229:20 at Array.forEach"
Any of you tried and got this error? I searched Google for a bit longer but i can't find this issue. And if i try to manager.getChanges() and put the changes in array, i get my entity with modified state.
The guys from breeze didn't covered this part and i'm completly blind in this. Thank you for your time guys.
I solved my problem. I included the modules in VS so i can debug and i noticed that breeze misnamed my collection name for some reason adding an s at the end.
Anyway.. for now i just removed that, and it works. I will dig deeper to see where and why is breeze adding an s at the end of my collection name because i want to treat the cause, not the effect. Thanks.

Error in objective C

I am trying to run unit test whereby I am getting an warning:
'FileName' may not respond to '-failWithException:'
I wanted to know why this warning occurs and how to fix that?
Either the FileName interface does not declare the failWithException: method, or you have not imported the header file in which the interface is declared.
Whatever sort of object FileName is, the compiler can't find a method named '-failWithException' in that class. The solution is to go implement that method on that class, or to make sure the compiler can find the header file where it already is implemented.
By the way, it's a warning instead of an error because, unlike for instance Java, Objective-C allows you to manipulate classes at runtime. So while you PROBABLY have a problem there, you don't DEFINITELY have a problem, so the IDE gives you a yellow warning rather than a red error. But in your case, this is almost certainly something you need to fix.

Perl changing the current package?

Without using a source-filter, is there a way to change the current running package? I'm trying to accomplish the same thing oose.pm does, and I'm wondering if I can drop my users in a non-main package.
I think you'll be able to do that by changing PL_curstash and PL_curstname on the C level.
PL_curstash = gv_stashpvs("Some::Package", GV_ADD);
sv_setpvs(PL_curstname, "Some::Package");
PL_curstash is the stash of the current package during compilation, PL_curstname is its name.
Update:
I've found this problem kind of interesting and implemented the solution as Devel::ChangePackage. Turns out what I initially suggested just works. You can get it either from http://github.com/rafl/devel-changepackage, or from a CPAN mirror near you once they have updated.

What can make Class::Loader fail where "use" and "new" do not?

I'm working on a very large CGI application that uses Crypt::RSA, which is properly installed. I get a "attempted to call a null reference as a function" type of error (I can't go back to get the exact error right now because we had to rollback for a release date) when I try to run any the embedded library. I trace the null reference to Crypt::RSA's constructor, which uses Class::Loader to enable Crypt::RSA::ES::OAEP.
I replaced the class loader with a "use" and a "new", and that part works fine, though the library still fails in many points. Obviously something is wrong with my environment. I'm just not certain as to what. Can anyone give me any leads?
Ok, after 12 hours of digging into it, I got this working.
Here's what was going on (but not why). Whenever I called eval() on a quoted use or require statement (as occurs in Class::Loader, but also in other locations in the Crypt:: framwork), it failed to see paths that were otherwise included as Perl classpaths. Since most quoted use/require objects simply assume the class will be there, very few useful errors were thrown out at me. I would dump #INC to file, outside an eval block, and everything would be there.
Ironically, I used the same setup in dev vs staging, and it worked in dev, but not in staging. I must also point out that FindBin (I shouldn't be using it in CGI, I know, but Crypt uses it) was flailing up and down about /dev/null in staging, but not in development.
Since I can't easily compare versions or global configs, that's where my quest ends.
How I resolved the issue for myself in Crypt::RSA was to disable all commands tied to FindBin, and hard-code require references for anything my code would ever access. I did a require in Crypt::RSA for Crypt::RSA::ES::OAEP and one in Crypt::Random::Generator for Crypt::Random::Provider::rand
Hope this helps anyone in the future who has the problem. Anyone who can suggest the why of it, please respond and I'll add it to complete the post.