in reply to Re: Boolean operators and list assignments
in thread Boolean operators and list assignments

Sorry that was a typing problem.
it should be if ($siteslisted >= $sitesperpage) {last;}
I am really confused, because I'd expect
that a expression that can be used at a boolean on it's own
should be usable with a boolean operator.
"Sometimes it's hard to tell the dancer from the dance."-Corwin in CoC
  • Comment on Re: Re: Boolean operators and list assignments

Replies are listed 'Best First'.
(tye)Re: Boolean operators and list assignments
by tye (Sage) on Dec 20, 2000 at 23:47 UTC

    So are we (confused). You should probably do that standard work that you should always do when you run into a problem:

    Take the code that produces the problem and reduce it to a minimal example that reproduces the problem. You will likely discover the source of the problem when doing this. If you don't find the solution, then post exactly the very small script that reproduces the problem along with the exact input, output (including error messages), and what about the output you didn't like.

            - tye (but my friends call me "Tye")
Re: Re: Re: Boolean operators and list assignments
by chipmunk (Parson) on Dec 20, 2000 at 23:55 UTC
    Okay, that clears up that little issue.

    I tried both of your code structures, and they both worked fine, stopping after $sitesperpage fetches from the database. I wonder if there is a bug in the actual code that isn't reflected in the posted code. Perhaps a mispelled variable name or something like that? Are you using -w and use strict?

      O well. Maybe I fixed my error in typing it. I no longer have the original code. But that loop took down apache. (Each iteration of the loop I was pushing
      some results to a list.) Apache's logs show it died due to malloc failing. I'm using both -w and use strict, so that's not the problem.

      "Sometimes it's hard to tell the dancer from the dance."-Corwin in CoC