GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  MDOM::TOKEN::COMMENT (3)

.ds Aq ’

NAME

MDOM::Token::Comment - A comment in Makefile source code

CONTENTS

INHERITANCE



  MDOM::Token::Comment
  isa MDOM::Token
      isa MDOM::Element



SYNOPSIS



  # This is a MDOM::Token::Comment

  foo: bar # So is this one
        echo hello



DESCRIPTION

In MDOM, comments are represented by MDOM::Token::Comment objects.

These come in two flavours, line comment and inline comments.

A line comment is a comment that stands on its own line. These comments hold their own newline and whitespace (both leading and trailing) as part of the one MDOM::Token::Comment object.

An inline comment is a comment that appears after some code, and continues to the end of the line. This does <B>notB> include whitespace, and the terminating newlines is considered a separate MDOM::Token::Whitespace token.

This is largely a convenience, simplifying a lot of normal code relating to the common things people do with comments.

Most commonly, it means when you prune or delete a comment, a line comment disappears taking the entire line with it, and an inline comment is removed from the inside of the line, allowing the newline to drop back onto the end of the code, as you would expect.

It also means you can move comments around in blocks much more easily.

For now, this is a suitably handy way to do things. However, I do reserve the right to change my mind on this one if it gets dangerously anachronistic somewhere down the line.

METHODS

Only very limited methods are available, beyond those provided by our parent MDOM::Token and MDOM::Element classes.

    line

The line accessor returns true if the MDOM::Token::Comment is a line comment, or false if it is an inline comment.

SUPPORT

See the support section in the main module.

AUTHOR

Adam Kennedy <adamk@cpan.org>

COPYRIGHT

Copyright 2001 - 2006 Adam Kennedy.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

The full text of the license can be found in the LICENSE file included with this module.

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 MDOM::TOKEN::COMMENT (3) 2014-11-19

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.