Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8017499
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T20:51:41+00:00 2026-06-04T20:51:41+00:00

This compiler like: let test Xf Yf = Xf + Yf This compiler no

  • 0

This compiler like:

let test Xf Yf = Xf + Yf

This compiler no like:

let test Xfd Yfd = Xfd + Yfd

Warning:
Uppercase variable identifiers should not generally be used in patterns, and may indicate a misspelt pattern name.

Maybe I’m not googling properly, but I haven’t managed to track down anything which explains why this is the case for function parameters…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T20:51:42+00:00Added an answer on June 4, 2026 at 8:51 pm

    I agree that this error message looks a bit mysterious, but there is a good motivation for it. According to the F# naming guidelines, cases of discriminated unions should be named using PascalCase and the compiler is trying to make sure that you don’t accidentally misspell name of a case in pattern matching.

    For example, if you have the following union:

    type Side = 
      | Left 
      | Right
    

    You could write the following function that prints “ok” when the argument is Left and “wrong!” otherwise:

    let foo a = 
      match a with 
      | Lef -> printfn "ok"
      | _ -> printfn "wrong!"
    

    There is a typo in the code – I wrote just Lef – but the code is still valid, because Lef can be interpreted as a new variable and so the matching assigns whatever side to Lef and always runs the first case. The warning about uppercase identifiers helps to avoid this.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In gcc I can do compile-time warnings like this: #if !defined(_SOME_FEATURE_) #warning _SOME_FEATURE_ not
For example, I get this compiler warning, The event 'Company.SomeControl.SearchClick' is never used. But
I tried to catch an Exception but the compiler gives warning: This type test
The .Net model is something like this : C# Code -> C# Compiler ->
I just found my code like this does not compile right? Is there any
I am getting this compiler (gcc 4.5) warning: Formatter.cpp:23: warning: unknown conversion type character
I am not overly competent in C++ and this compiler error is just making
I have a function defined like this: let test_func lis = match lis with
Right now, if you have a test that looks like this: [TestMethod] [DeploymentItem(DataSource.csv)] [DataSource(
Let's say I have two anonymous objects like this: var objA = new {

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.