Upgrade to Pro — share decks privately, control downloads, hide ads and more …

C# 7.0 - What's New (Show IT, Bratislava, 2017)

C# 7.0 - What's New (Show IT, Bratislava, 2017)

Syntax Enhancements with C# 7.0

Christian Nagel

February 07, 2017
Tweet

More Decks by Christian Nagel

Other Decks in Programming

Transcript

  1. History of C#
    •OO & Component Oriented
    1.0
    •Generics
    2.0
    •LINQ
    3.0
    •Dynamic
    4.0
    •Async
    5.0
    •Roslyn & Many Improvement's
    6.0

    View full-size slide

  2. C# 7.0 – What’s New?
    Christian Nagel
    @christiannagel
    [email protected]

    View full-size slide

  3. Agenda
    History of
    C#
    C# Goals New Syntax
    with C# 7.0

    View full-size slide

  4. Christian Nagel
    • Training
    • Coaching
    • Consulting
    • Microsoft MVP
    • thinktecture
    • www.cninnovation.com

    View full-size slide

  5. C# IS A MULTI-PARADIGM LANGUAGE!

    View full-size slide

  6. Typical Applications
    SQL
    Azure
    App Services
    WPF
    UWP
    Xamarin
    Storage

    View full-size slide

  7. What’s Needed?
    • Separation of Functionality and State
    • Immutable Objects
    •  Functional Programming can help

    View full-size slide

  8. Functional Programming
    • Functions as 1st-Class
    • Avoiding State Mutation

    View full-size slide

  9. C# 6 Features for Functional
    Programming
    • Using Static
    • Enhancements with Properties
    • Expression Bodied Methods
    • Exception Filters
    • String Interpolation
    • Null Conditional Operator

    View full-size slide

  10. NEW SYNTAX WITH C# 7.0

    View full-size slide

  11. SAMPLE CODING…

    View full-size slide

  12. C# 7.0 Enhancements
    • Digit Separators and Binary Literals
    • Out Var, Ref Local and Ref Return
    • Local Functions
    • Expression Syntax Everywhere
    • Pattern Matching
    • Tuples and Deconstruction

    View full-size slide

  13. Summary
    • C# is a Multi-Paradigm Language
    • Influences from Functional Programming
    • Major new Features
    – Tuples and Deconstruction
    – Pattern Matching

    View full-size slide

  14. More Information (1)
    • https://dot.net
    • https://github.com/dotnet/csharplang
    • Sample Code:
    • https://github.com/CNinnovation

    View full-size slide

  15. More Information (2)
    • https://github.com/ProfessionalCSharp
    • https://csharp.christiannagel.com
    • https://www.cninnovation.com
    • Training & Coaching

    View full-size slide

  16. Images Copyright
    • Violin © Beyla Balla
    • Ladder to the Sky © Louise Reach
    • Diversity working people © Vladimir Mucibabic
    • Code Coding Programming Sire © Rawpixelimages
    • Problem Solving Series © Pablo631
    • Bratislava © Tomas1111
    • http://www.dreamstime.com

    View full-size slide

  17. www.showit.sk
    www.gopas.sk

    View full-size slide