• 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: Problems with assembly "or" instruction...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problems with assembly "or" instruction...


  • Subject: Re: Problems with assembly "or" instruction...
  • From: Jerry <email@hidden>
  • Date: Fri, 11 Feb 2005 06:39:48 +0000


On 10 Feb 2005, at 23:19, Dave Thorup wrote:

I'm moving a CFM project from CodeWarrior to Xcode and Mach-o and I've run into a problem when compiling some assembly. I've got a function as follows:

static asm unsigned long Mul32Shft16r( register unsigned long val1, register unsigned long val2 )
{
// a bunch of assmebly that compiles fine
// ...
// v-- then I get a problem with this line --v

or r3,r30,r31
}

The problem I get is as follows:

<x-tad-smaller>error: parse error before `||' token

</x-tad-smaller>
Does anyone have any suggestions? It's like GCC is converting the "or" into a "||" and then getting confused. This is the only bit of assembly that doesn't compile, everything else works fine.

"or" is a reserved word in C++ (you'll see it changes colour when you type it in). It one of a group of alternative representations for operators. I suspect, as you say, that the compiler just changes it to ||. I don't know what your workround is - maybe compile as C instead of C++?

Jerry

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Problems with assembly "or" instruction... (From: Dave Thorup <email@hidden>)

  • Prev by Date: Re: Problems with assembly "or" instruction...
  • Next by Date: breakpoints sometimes stop at the beginning of a C++ method
  • Previous by thread: Re: Problems with assembly "or" instruction...
  • Next by thread: Re: Problems with assembly "or" instruction...
  • Index(es):
    • Date
    • Thread