• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Pasting code (Was: Re: Obj-C with C problems)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Pasting code (Was: Re: Obj-C with C problems)


  • Subject: Re: Pasting code (Was: Re: Obj-C with C problems)
  • From: Daniel Gregg <email@hidden>
  • Date: Thu, 24 May 2001 13:15:39 -0500

I'll definitely look for it. I need something like that. Sometimes I feel so stupid because I've had this same thing happen before and I spent hours resolving the problem, chasing nonexistent bugs. You'd think I'd learn and suspect this sort of thing every time I get 72 errors in one small source file!!! The reason I initially asked why my example wouldn't compile,with the function declaration and definition in a separate .c file, was because I commented out ALL of the pasted code, leaving nothing but comments, then added the quick dec and def to that .c file. Still didn't compile. Later I moved the dec and def to the .m file where that routine is called and it compiled just fine. Hence my first email. Immediately after that, i created a completely new .c file and put in my dec and def, it of course compiled just fine. So I turned to the notion of file "corruption". I hand entered in the text that I had pasted, into a new file....compiled just fine even though the two files were identical on the screen!

So yes, the embedded characters will "byte" ya!!

Sorry Tony if I wasted your time, I tried to follow up as soon as I could.

But hey, maybe we all learned something, hopefully I can find TextExtras.

d
On Thursday, May 24, 2001, at 12:16 PM, Annard Brouwer wrote:

On Thursday, May 24, 2001, at 04:59 , Daniel Gregg wrote:
The problem was that I had a large amount of code that I had Copy-Pasted from IE into my file. Apparently, it creates 6 Billion cryptic errors when the code is otherwise just fine.

This happened to me a lot in my OpenStep days. I can't find it now but if you download and install TextExtras you can create a User Pipe that filters out all 8 bit characters from the text on the pasteboard and pastes it back into your editor. You could use the Unix utility "tr" to achieve this.
Isn't it handy to have the power of Unix at your fingertips?

Annard


References: 
 >Pasting code (Was: Re: Obj-C with C problems) (From: Annard Brouwer <email@hidden>)

  • Prev by Date: Re: Icon in window title
  • Next by Date: Re: Icon in window title
  • Previous by thread: Pasting code (Was: Re: Obj-C with C problems)
  • Next by thread: beginSheet:modalForWindow:modalDelegate:didEndSelector:contextI nfo:
  • Index(es):
    • Date
    • Thread