---
title: "'Course, that doesn't work when 'a' contains parentheses. — Larry Wall Quote #146 | QuotesBy.net"
description: "'Course, that doesn't work when 'a' contains parentheses. — a quote by Larry Wall."
image: "https://quotesby.net/wp-content/themes/quotesby-editorial/assets/og-default.png"
---

> # 'Course, that doesn't work when 'a' contains parentheses.

[Larry Wall](https://quotesby.net/Larry-Wall)\#146

[Programming](https://quotesby.net/Larry-Wall/programming/)[Parsing](https://quotesby.net/Larry-Wall/parsing/)[Validation](https://quotesby.net/topics/validation/)

[WhatsApp (opens in a new tab)](https://wa.me/?text=%E2%80%9C%27Course%2C%20that%20doesn%27t%20work%20when%20%27a%27%20contains%20parentheses.%E2%80%9D%20%E2%80%94%20Larry%20Wall%20https%3A%2F%2Fquotesby.net%2FLarry-Wall%2F146%2F)[X (opens in a new tab)](https://twitter.com/intent/tweet?text=%E2%80%9C%27Course%2C%20that%20doesn%27t%20work%20when%20%27a%27%20contains%20parentheses.%E2%80%9D%20%E2%80%94%20Larry%20Wall&url=https%3A%2F%2Fquotesby.net%2FLarry-Wall%2F146%2F)[Facebook (opens in a new tab)](https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fquotesby.net%2FLarry-Wall%2F146%2F)

## About this quote

What does it mean?Wall points out that a solution fails when the variable contains parentheses.In plain termsThe method breaks if the input has parentheses.What can you take from it?Check for special characters that may break parsing.

### Where it applies

- input handling
- command line tools

### Putting it to work

- sanitize input
- escape parentheses

### Questions to consider

- What other characters could cause similar issues?

### Another view

Only mentions one specific failure mode.

## More from Larry Wall

1. > That gets us out of deciding how to spell Reg\[eE\]xp?\|RE . . . Of course, then we have to decide what ref $re returns... :-)

[Permalink to quote \#145](https://quotesby.net/Larry-Wall/145/ "Permalink to quote 145")
2. > I was trying not to mention backtracking. Which, of course, means that yours is 'righter' than mine, in a theoretical sense.

[Permalink to quote \#147](https://quotesby.net/Larry-Wall/147/ "Permalink to quote 147")
3. > That should probably be written: no !@#$%^&amp;\*:@!semicolon

[Permalink to quote \#144](https://quotesby.net/Larry-Wall/144/ "Permalink to quote 144")

## Related quotes

1. > There are probably better ways to do that, but it would make the parser more complex. I do, occasionally, struggle feebly against complexity... :-)

[Larry Wall](https://quotesby.net/Larry-Wall)[Larry Wall quote \#23](https://quotesby.net/Larry-Wall/23/ "Permalink to quote 23")
2. > /\* This bit of chicanery makes a unary function followed by a parenthesis into a function with one argument, highest precedence. \*/

[Larry Wall](https://quotesby.net/Larry-Wall)[Larry Wall quote \#264](https://quotesby.net/Larry-Wall/264/ "Permalink to quote 264")
3. > A lot of times black folks look for love in all the wrong places. You're always looking for somebody to love you, be accepted, and there's the insecurities tha…

[Chuck D](https://quotesby.net/Chuck-D)[Chuck D quote \#1](https://quotesby.net/Chuck-D/1/ "Permalink to quote 1")

```json
{
    "@context": "https://schema.org",
    "@type": "Quotation",
    "text": "'Course, that doesn't work when 'a' contains parentheses.",
    "url": "https://quotesby.net/Larry-Wall/146/",
    "spokenByCharacter": {
        "@type": "Person",
        "name": "Larry Wall"
    }
}
{
    "@context": "https://schema.org",
    "@type": "BreadcrumbList",
    "itemListElement": [
        {
            "@type": "ListItem",
            "position": 1,
            "name": "Home",
            "item": "https://quotesby.net/"
        },
        {
            "@type": "ListItem",
            "position": 2,
            "name": "Authors",
            "item": "https://quotesby.net/authors/"
        },
        {
            "@type": "ListItem",
            "position": 3,
            "name": "Larry Wall",
            "item": "https://quotesby.net/Larry-Wall"
        },
        {
            "@type": "ListItem",
            "position": 4,
            "name": "Quote #146",
            "item": "https://quotesby.net/Larry-Wall/146/"
        }
    ]
}
```
