Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #112055

Re: Scope of identifiers

From Keith Thompson <kst-u@mib.org>
Newsgroups comp.lang.c
Subject Re: Scope of identifiers
Date 2017-06-12 09:38 -0700
Organization None to speak of
Message-ID <lnink1gnzy.fsf@kst-u.example.com> (permalink)
References <ohmea9$nft$1@gioia.aioe.org>

Show all headers | View raw


Steve Keller <keller@no.invalid> writes:
> While reading again in the standard about declarations and (tentative)
> definitions, and linkage, I also read about scope of identifiers and
> was confused:
>
> The standard says in 6.2.1p6 that "two identifiers have the same
> scope if and only if their scopes terminate at the same point."

Yes, and the phrase "same scope" is in italics, which means this is the
definition of the term.  Two identifiers can have the *same scope*
even if their scopes begin in different places.

It might have been less confusing if the standard had used a different
phrase, perhaps "matching scope".

[...]

-- 
Keith Thompson (The_Other_Keith) kst-u@mib.org  <http://www.ghoti.net/~kst>
Working, but not speaking, for JetHead Development, Inc.
"We must do something.  This is something.  Therefore, we must do this."
    -- Antony Jay and Jonathan Lynn, "Yes Minister"

Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Scope of identifiers Steve Keller <keller@no.invalid> - 2017-06-12 18:08 +0200
  Re: Scope of identifiers "James R. Kuyper" <jameskuyper@verizon.net> - 2017-06-12 12:22 -0400
    Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-12 09:39 -0700
  Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-12 09:38 -0700
    Re: Scope of identifiers "James R. Kuyper" <jameskuyper@verizon.net> - 2017-06-12 14:41 -0400
      Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-12 12:39 -0700
        Re: Scope of identifiers "James R. Kuyper" <jameskuyper@verizon.net> - 2017-06-12 15:53 -0400
          Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-12 13:19 -0700
            Re: Scope of identifiers David Kleinecke <dkleinecke@gmail.com> - 2017-06-13 11:01 -0700
              Re: Scope of identifiers jameskuyper@verizon.net - 2017-06-13 11:25 -0700
              Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-13 12:16 -0700
                Re: Scope of identifiers David Kleinecke <dkleinecke@gmail.com> - 2017-06-13 21:02 -0700
                Re: Scope of identifiers Ian Collins <ian-news@hotmail.com> - 2017-06-14 21:53 +1200
                Re: Scope of identifiers supercat@casperkitty.com - 2017-06-14 08:10 -0700
                Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-14 09:19 -0700
                Re: Scope of identifiers supercat@casperkitty.com - 2017-06-14 10:14 -0700
                Re: Scope of identifiers Keith Thompson <kst-u@mib.org> - 2017-06-14 09:12 -0700
  Re: Scope of identifiers Robert Wessel <robertwessel2@yahoo.com> - 2017-06-12 13:02 -0500

csiph-web