Tierless Web programming languages allow programmers to combine client-side and server-side programming in a single program. Programmers can then define components with both client and server parts and get flexible, efficient and typesafe client-server communications. However, the expressive client-server features found in most tierless languages are not necessarily compatible with functionalities found in many mainstream languages. In particular, we would like to benefit from type safety, an efficient execution, static compilation, modularity and separate compilation.In this paper, we propose E , an industrial-strength tierless functional Web programming language which extends OC with support for rich client/server interactions. It allows to build whole applications as a single distributed program, in which it is possible to define modular tierless libraries with both server and client behaviors and combine them effortlessly. E is the only language that combines type-safe and efficient client/server communications with a static compilation model that supports separate compilation and modularity. It also supports excellent integration with OC , allowing to transparently leverage its ecosystem.To achieve all these features, E borrows ideas not only from distributed programming languages, but also from meta-programming and modern module systems. We present the design of E , how it can be used in practice and its formalization; including its type system, semantics and compilation scheme. We show that this compilation scheme preserves typing and semantics, and that it supports separate compilation.This juggling of many different technologies does not only make programming more complicated, it also imposes strong constraints on code organization and prevents modularity. Let us consider the case where we want to add a comment widget to a website. This widget requires J S code for client interactions, for example a convenient editor. It also requires server code that will store and serve the comments and potentially some associated database queries. This code will thus be split in two codebases and up to three languages. Furthermore, in order to be properly integrated in the larger website, the internal communications between the client and server parts of the widget will be exposed to the rest of the program. All these programming constraints, which stem directly from the way Web programming is done currently, make it impossible to preserve abstraction and encapsulation for widgets who have both client and server aspects. This hinders safety and reusability of widgets by preventing programmers to create selfcontained independent libraries that have both client and server aspects.: A Language for Modular Tierless Web Programming :3programming often relies on numerous external libraries (for encryption, HTML, logging, . . . ). We wanted to leverage all the existing tools and libraries developed either in the O project or the larger OC ecosystem. The design of a Modular Tierless languageTo build such a language with suppo...
We present a complete method for synthesizing lexicographic linear ranking functions, supported by inductive invariants, in the case where the transition relation includes disjunctions and existentials (large block encoding of complex control flow).Previous work would expand the transition relation into disjunctive normal form, or equivalently would expand the block transition into (exponentially many) elementary transitions, prior to computing the ranking function, resulting in a very large global constraint system. In contrast, our algorithm sees elementary transitions only as needed, and builds a global constraint system lazily.
Systems programming often requires the manipulation of resources like file handles, network connections, or dynamically allocated memory. Programmers need to follow certain protocols to handle these resources correctly. Violating these protocols causes bugs ranging from type mismatches over data races to use-after-free errors and memory leaks. These bugs often lead to security vulnerabilities. While statically typed programming languages guarantee type soundness and memory safety by design, most of them do not address issues arising from improper handling of resources. An important step towards handling resources is the adoption of linear and affine types that enforce single-threaded resource usage. However, the few languages supporting such types require heavy type annotations. We present Affe, an extension of ML that manages linearity and affinity properties using kinds and constrained types. In addition Affe supports the exclusive and shared borrowing of affine resources, inspired by features of Rust. Moreover, Affe retains the defining features of the ML family: it is an impure, strict, functional expression language with complete principal type inference and type abstraction. Affe does not require any linearity annotations in expressions and supports common functional programming idioms. CCS Concepts: • Software and its engineering → Semantics; Functional languages.
Language-integrated query techniques have been explored in a number of different language designs. We consider two different, type-safe approaches employed by Links and F#. Both approaches provide rich dynamic query generation capabilities, and thus amount to a form of heterogeneous staged computation, but to date there has been no formal investigation of their relative expressiveness. We present two core calculi Eff and Quot, respectively capturing the essential aspects of language-integrated querying using effects in Links and quotation in LINQ. We show via translations from Eff to Quot and back that the two approaches are equivalent in expressiveness. Based on the translation from Eff to Quot, we extend a simple Links compiler to handle queries.
HAL is a multidisciplinary open access archive for the deposit and dissemination of scientific research documents, whether they are published or not. The documents may come from teaching and research institutions in France or abroad, or from public or private research centers. L'archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d'enseignement et de recherche français ou étrangers, des laboratoires publics ou privés.
Regular expressions are part of every programmer's toolbox. They are used for a wide variety of language-related tasks and there are many algorithms for manipulating them. In particular, matching algorithms that detect whether a word belongs to the language described by a regular expression are well explored, yet new algorithms appear frequently. However, there is no satisfactory methodology for testing such matchers. We propose a testing methodology which is based on generating positive as well as negative examples of words in the language. To this end, we present a new algorithm to generate the language described by a generalized regular expression with intersection and complement operators. The complement operator allows us to generate both positive and negative example words from a given regular expression. We implement our generator in Haskell and OCaml and show that its performance is more than adequate for testing. CCS Concepts • Theory of computation → Regular languages; Grammars and context-free languages; • Software and its engineering → Software testing and debugging; Functional languages;
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.
hi@scite.ai
10624 S. Eastern Ave., Ste. A-614
Henderson, NV 89052, USA
Copyright © 2024 scite LLC. All rights reserved.
Made with 💙 for researchers
Part of the Research Solutions Family.