What exactly is the linear whitespace? (LWS/LWSP)











up vote
20
down vote

favorite
5












I saw mention of the term, along with CRLF, CR, LF, CTL (control characters) and SP (space).



If it's not the regular inline whitespace ( ), so what character(s) is it?










share|improve this question


























    up vote
    20
    down vote

    favorite
    5












    I saw mention of the term, along with CRLF, CR, LF, CTL (control characters) and SP (space).



    If it's not the regular inline whitespace ( ), so what character(s) is it?










    share|improve this question
























      up vote
      20
      down vote

      favorite
      5









      up vote
      20
      down vote

      favorite
      5






      5





      I saw mention of the term, along with CRLF, CR, LF, CTL (control characters) and SP (space).



      If it's not the regular inline whitespace ( ), so what character(s) is it?










      share|improve this question













      I saw mention of the term, along with CRLF, CR, LF, CTL (control characters) and SP (space).



      If it's not the regular inline whitespace ( ), so what character(s) is it?







      character special-characters whitespace






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Jan 12 '14 at 8:24









      Reflection

      8571924




      8571924
























          1 Answer
          1






          active

          oldest

          votes

















          up vote
          31
          down vote



          accepted










          From STD68 Augmented BNF for Syntax Specifications: ABNF



          LWSP    =  *(WSP / CRLF WSP)  ; Use of this linear-white-space rule permits
          ; lines containing only white space*
          WSP = SP / HTAB ; white space
          CRLF = CR LF ; Internet standard newline
          SP = %x20 ; space
          HTAB = %x09 ; horizontal tab
          CR = %x0D ; carriage return
          LF = %x0A ; linefeed


          The comment on LWSP has changed in STD68 (aka RFC5234) from RFC2234 and RFC4234 and now gives advice against using this definition in new documents.



          In plain English: Linear white space is: any number of spaces or horizontal tabs, and also newline (CRLF) if it is followed by at least one space or horizontal tab.



          Example of strings that are linear white space:




          • [SP]

          • [HTAB]

          • [SP][SP]

          • [HTAB][HTAB]

          • [SP][HTAB][SP]

          • [SP][CR][LF][SP]

          • [CR][LF][SP][CR][LF][SP][CR][LF][HTAB]

          • [SP][CR][LF][CR][LF][SP][CR][LF][SP][CR][LF] This is TWO linear white spaces: [SP] and [SP][CR][LF][SP]. [CR][LF] is only included if it has [SP] or [HTAB] before and after.

          • [SP][VTAB][SP] Two linear white spaces: [SP] and [SP], separated by a Vertical tab.

          • [SP][CR][LF][CR][LF][CR][LF] Only the first [SP] is a linear white space. CRLF followed by CRLF is not part of specification




          Thanks to Jukka K. Korpela for reminding me to check for obsoleted RFCs and to unwind for clarification that CRLF must be followed by a space or htab to be part of LWSP.






          share|improve this answer























            Your Answer






            StackExchange.ifUsing("editor", function () {
            StackExchange.using("externalEditor", function () {
            StackExchange.using("snippets", function () {
            StackExchange.snippets.init();
            });
            });
            }, "code-snippets");

            StackExchange.ready(function() {
            var channelOptions = {
            tags: "".split(" "),
            id: "1"
            };
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function() {
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled) {
            StackExchange.using("snippets", function() {
            createEditor();
            });
            }
            else {
            createEditor();
            }
            });

            function createEditor() {
            StackExchange.prepareEditor({
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: true,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: 10,
            bindNavPrevention: true,
            postfix: "",
            imageUploader: {
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            },
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            });


            }
            });














            draft saved

            draft discarded


















            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f21072713%2fwhat-exactly-is-the-linear-whitespace-lws-lwsp%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown

























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            31
            down vote



            accepted










            From STD68 Augmented BNF for Syntax Specifications: ABNF



            LWSP    =  *(WSP / CRLF WSP)  ; Use of this linear-white-space rule permits
            ; lines containing only white space*
            WSP = SP / HTAB ; white space
            CRLF = CR LF ; Internet standard newline
            SP = %x20 ; space
            HTAB = %x09 ; horizontal tab
            CR = %x0D ; carriage return
            LF = %x0A ; linefeed


            The comment on LWSP has changed in STD68 (aka RFC5234) from RFC2234 and RFC4234 and now gives advice against using this definition in new documents.



            In plain English: Linear white space is: any number of spaces or horizontal tabs, and also newline (CRLF) if it is followed by at least one space or horizontal tab.



            Example of strings that are linear white space:




            • [SP]

            • [HTAB]

            • [SP][SP]

            • [HTAB][HTAB]

            • [SP][HTAB][SP]

            • [SP][CR][LF][SP]

            • [CR][LF][SP][CR][LF][SP][CR][LF][HTAB]

            • [SP][CR][LF][CR][LF][SP][CR][LF][SP][CR][LF] This is TWO linear white spaces: [SP] and [SP][CR][LF][SP]. [CR][LF] is only included if it has [SP] or [HTAB] before and after.

            • [SP][VTAB][SP] Two linear white spaces: [SP] and [SP], separated by a Vertical tab.

            • [SP][CR][LF][CR][LF][CR][LF] Only the first [SP] is a linear white space. CRLF followed by CRLF is not part of specification




            Thanks to Jukka K. Korpela for reminding me to check for obsoleted RFCs and to unwind for clarification that CRLF must be followed by a space or htab to be part of LWSP.






            share|improve this answer



























              up vote
              31
              down vote



              accepted










              From STD68 Augmented BNF for Syntax Specifications: ABNF



              LWSP    =  *(WSP / CRLF WSP)  ; Use of this linear-white-space rule permits
              ; lines containing only white space*
              WSP = SP / HTAB ; white space
              CRLF = CR LF ; Internet standard newline
              SP = %x20 ; space
              HTAB = %x09 ; horizontal tab
              CR = %x0D ; carriage return
              LF = %x0A ; linefeed


              The comment on LWSP has changed in STD68 (aka RFC5234) from RFC2234 and RFC4234 and now gives advice against using this definition in new documents.



              In plain English: Linear white space is: any number of spaces or horizontal tabs, and also newline (CRLF) if it is followed by at least one space or horizontal tab.



              Example of strings that are linear white space:




              • [SP]

              • [HTAB]

              • [SP][SP]

              • [HTAB][HTAB]

              • [SP][HTAB][SP]

              • [SP][CR][LF][SP]

              • [CR][LF][SP][CR][LF][SP][CR][LF][HTAB]

              • [SP][CR][LF][CR][LF][SP][CR][LF][SP][CR][LF] This is TWO linear white spaces: [SP] and [SP][CR][LF][SP]. [CR][LF] is only included if it has [SP] or [HTAB] before and after.

              • [SP][VTAB][SP] Two linear white spaces: [SP] and [SP], separated by a Vertical tab.

              • [SP][CR][LF][CR][LF][CR][LF] Only the first [SP] is a linear white space. CRLF followed by CRLF is not part of specification




              Thanks to Jukka K. Korpela for reminding me to check for obsoleted RFCs and to unwind for clarification that CRLF must be followed by a space or htab to be part of LWSP.






              share|improve this answer

























                up vote
                31
                down vote



                accepted







                up vote
                31
                down vote



                accepted






                From STD68 Augmented BNF for Syntax Specifications: ABNF



                LWSP    =  *(WSP / CRLF WSP)  ; Use of this linear-white-space rule permits
                ; lines containing only white space*
                WSP = SP / HTAB ; white space
                CRLF = CR LF ; Internet standard newline
                SP = %x20 ; space
                HTAB = %x09 ; horizontal tab
                CR = %x0D ; carriage return
                LF = %x0A ; linefeed


                The comment on LWSP has changed in STD68 (aka RFC5234) from RFC2234 and RFC4234 and now gives advice against using this definition in new documents.



                In plain English: Linear white space is: any number of spaces or horizontal tabs, and also newline (CRLF) if it is followed by at least one space or horizontal tab.



                Example of strings that are linear white space:




                • [SP]

                • [HTAB]

                • [SP][SP]

                • [HTAB][HTAB]

                • [SP][HTAB][SP]

                • [SP][CR][LF][SP]

                • [CR][LF][SP][CR][LF][SP][CR][LF][HTAB]

                • [SP][CR][LF][CR][LF][SP][CR][LF][SP][CR][LF] This is TWO linear white spaces: [SP] and [SP][CR][LF][SP]. [CR][LF] is only included if it has [SP] or [HTAB] before and after.

                • [SP][VTAB][SP] Two linear white spaces: [SP] and [SP], separated by a Vertical tab.

                • [SP][CR][LF][CR][LF][CR][LF] Only the first [SP] is a linear white space. CRLF followed by CRLF is not part of specification




                Thanks to Jukka K. Korpela for reminding me to check for obsoleted RFCs and to unwind for clarification that CRLF must be followed by a space or htab to be part of LWSP.






                share|improve this answer














                From STD68 Augmented BNF for Syntax Specifications: ABNF



                LWSP    =  *(WSP / CRLF WSP)  ; Use of this linear-white-space rule permits
                ; lines containing only white space*
                WSP = SP / HTAB ; white space
                CRLF = CR LF ; Internet standard newline
                SP = %x20 ; space
                HTAB = %x09 ; horizontal tab
                CR = %x0D ; carriage return
                LF = %x0A ; linefeed


                The comment on LWSP has changed in STD68 (aka RFC5234) from RFC2234 and RFC4234 and now gives advice against using this definition in new documents.



                In plain English: Linear white space is: any number of spaces or horizontal tabs, and also newline (CRLF) if it is followed by at least one space or horizontal tab.



                Example of strings that are linear white space:




                • [SP]

                • [HTAB]

                • [SP][SP]

                • [HTAB][HTAB]

                • [SP][HTAB][SP]

                • [SP][CR][LF][SP]

                • [CR][LF][SP][CR][LF][SP][CR][LF][HTAB]

                • [SP][CR][LF][CR][LF][SP][CR][LF][SP][CR][LF] This is TWO linear white spaces: [SP] and [SP][CR][LF][SP]. [CR][LF] is only included if it has [SP] or [HTAB] before and after.

                • [SP][VTAB][SP] Two linear white spaces: [SP] and [SP], separated by a Vertical tab.

                • [SP][CR][LF][CR][LF][CR][LF] Only the first [SP] is a linear white space. CRLF followed by CRLF is not part of specification




                Thanks to Jukka K. Korpela for reminding me to check for obsoleted RFCs and to unwind for clarification that CRLF must be followed by a space or htab to be part of LWSP.







                share|improve this answer














                share|improve this answer



                share|improve this answer








                edited Nov 11 at 23:05

























                answered Jan 12 '14 at 8:38









                some

                35k116379




                35k116379






























                    draft saved

                    draft discarded




















































                    Thanks for contributing an answer to Stack Overflow!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.





                    Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


                    Please pay close attention to the following guidance:


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid



                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.


                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function () {
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f21072713%2fwhat-exactly-is-the-linear-whitespace-lws-lwsp%23new-answer', 'question_page');
                    }
                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Florida Star v. B. J. F.

                    Danny Elfman

                    Retrieve a Users Dashboard in Tumblr with R and TumblR. Oauth Issues